package cn.lf.controller;

import cn.lf.dto.api.shop.ShopInoRepDTO;
import cn.lf.service.ApiShopInfoService;
import cn.lf.utils.ResponseModel;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/shop-info")
@Api(tags = "店铺信息相关接口")
public class ApiShopInfoController {

    @Autowired
    private ApiShopInfoService shopInfoService;

    @GetMapping("getShopInfoById")
    @ApiOperation("获取店铺信息")
    public ResponseModel<ShopInoRepDTO> getShopInfoById(@RequestParam String shopId){

        ShopInoRepDTO result = shopInfoService.getShopInfoById(shopId);

        return ResponseModel.buildSuccessResult(result);
    }

}
